var self = this;
$(function () {
    var f = function () {
        console.error('ran at ' + new Date(), window.nextTimeout);
        var selectors = [
            '.right_ads',
            'iframe',
            '.top_ads'
        ];

        _.forEach(selectors, function (selector) {
            if ($(selector).size() > 0) {
                console.log(selector + ': Killed ' + $(selector).size() + ' instances');
                $(selector).remove();
            }
        });

        $('body').removeAttr('style');

        if (isNaN(window.nextTimeout)) {
            window.nextTimeout = 1;
        }

        window.nextTimeout *= 2;
        window.setTimeout(f, window.nextTimeout);
    };

    f();
});